package com.gu.dao;

import com.gu.entity.Setting;
import com.gu.mapper.SettingMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
* The Table gu_user.
* 系统用户表
*/
@Repository
public class SettingDAO {

    @Autowired
    private SettingMapper settingMapper;

    public int deleteByPrimaryKey(Integer id) {
        return settingMapper.deleteByPrimaryKey(id);
    }

    public int insert(Setting record) {
        return settingMapper.insert(record);
    }

    public int insertSelective(Setting record) {
        return settingMapper.insertSelective(record);
    }

    public Setting selectByPrimaryKey(Integer id) {
        return settingMapper.selectByPrimaryKey(id);
    }

    public int updateByPrimaryKeySelective(Setting record) {
        return settingMapper.updateByPrimaryKeySelective(record);
    }

    public int updateByPrimaryKey(Setting record){
        return settingMapper.updateByPrimaryKey(record);
    }

    public Setting selectSettingByModuleAndName(String module,String name){
        return settingMapper.selectSettingByModuleAndName(module, name);
    }

    public List<Setting> getAllSetting(){
        return settingMapper.getAllSetting();
    }


}
